<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page import="com.parfinex.sims.entity.User" %>
<%@ page import="com.parfinex.sims.entity.ClassInfo" %><%--
  Created by IntelliJ IDEA.
  User: lijh
  Date: 2021-11-16
  Time: 0:08
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <title>学生信息管理系统-主页</title>
    <link rel="stylesheet" href="static/css/bootstrap.min.css">
</head>
<body>
<%--加载导航栏的头部文件--%>
<jsp:include page="common/header.jsp" />
<%--    <%@include file="common/header.jsp"%>--%>
<%--    <jsp:forward page="/QueryClassServlet"></jsp:forward>--%>
    <div class="container-fluid">
        <div class="row">
            <div class="col-md-8">
                <form class="form-inlIne" action="QueryClassServlet" method="post">
                    <div class="form-group">
                        <label for="queryClassName" class="control-label">请输入要查询的班级名称：</label>
                        <input type="text" class="form-control" id="queryClassName" name="queryClassName">
                    </div>
                    <button type="submit" class="btn btn-default">查询</button>
                </form>
            </div>
            <div class="col-md-4">
                <input type="button" class="btn btn-primary" name="newclass" id="newclass" value="创建班级" onclick="javaScript:window.location.href='createclass.jsp';">
            </div>
        </div>
    </div>
2
    <div class="table-responsive">
        <table class="table table-hover">
            <caption class="text-center" ><h1>拉勾教育-班级信息管理</h1></caption>
            <thead>
            <tr>
                <th>班级名称</th>
                <th>年级</th>
                <th>班主任名称</th>
                <th>班级口号</th>
                <th>班级人数</th>
                <th>操作</th>
            </tr>
<%--            <jsp:useBean id="classInfos" scope="page" class="com.parfinex.sims.servlet.QueryClassServlet" />--%>
            <tr>
                <c:forEach var="classInfos" items="${classInfos}">
                    ${list}<br>
                </c:forEach>
                <th></th>
            </tr>
            <% int tableSize =4; %>
            <%
                for (int i =0;i<tableSize;i++) {
            %>

            <tr>
                <th>${classInfos}</th>
                <th>${classInfo.getGradeName()}</th>
                <th>${classInfo.getMasterTeacher()}</th>
                <th>${classInfo.getClassSlogan()}</th>
                <th>${classInfo.getClassNumberCount()}</th>
                <th><button class="btn btn-default">修改</button><button class="btn btn-default">删除</button> </th>
            </tr>
            <%
                }
            %>
            </thead>
        </table>

        <nav aria-label="Page navigation">
            <ul class="pagination">
                <li>
                    <a href="#" aria-label="Previous">
                        <span aria-hidden="true">&laquo;</span>
                    </a>
                </li>
                <li><a href="#">1</a></li>
                <li><a href="#">2</a></li>
                <li><a href="#">3</a></li>
                <li><a href="#">4</a></li>
                <li><a href="#">5</a></li>
                <li>
                    <a href="#" aria-label="Next">
                        <span aria-hidden="true">&raquo;</span>
                    </a>
                </li>
            </ul>
        </nav>
    </div>
<%@include file="common/footer.jsp"%>
</body>
</html>
